﻿@model Zatify.WebUI.Admin.Models.AddNewCategoryViewModel
<style type="text/css">
    #tableCategory
    {
        width: 340px;
    }
    #tableCategory tr td
    {
        padding-bottom: 10px;
    }
    #tableCategory tr td.tdInput
    {
        padding-bottom: 5px;
        padding-left: 10px;
    }
</style>
<div id="overlay" class="web_dialog_overlay">
</div>
<div id="addNewCategory_Popup" class="web_dialog">
    <table style="width: 100%; border: 0px;" cellpadding="3" cellspacing="0">
        <tr>
            <td class="web_dialog_title">
                Add New Categories
            </td>
            <td class="web_dialog_title align_right">
                <a href="#" id="btnClose">X</a>
            </td>
        </tr>
        <tr>
            <td class="dialogContent" colspan="2">
                <div>
                    @using (Html.BeginForm("AddCategory", "Categories"))
                    {
                        <fieldset>
                            <legend>
                                <h4>
                                    Add New Categories</h4>
                            </legend>
                            <div class="add_new_user_form">
                                <table id="tableCategory">
                                    <tr>
                                        <td>
                                            <label for="CategoryName">
                                                Name:</label>
                                        </td>
                                        <td class="tdInput">
                                            @Html.TextBoxFor(c => c.CategoryName, new { @class = "apps_inputbox", placeholder = "Enter New Categories Name" })
                                            @Html.ValidationMessageFor(c => c.CategoryName, "*", new { title = "Category Name is rquired" })
                                        </td>
                                    </tr>
                                    <tr>
                                        <td>
                                            <label for="CategoryName">Description:</label>
                                        </td>
                                        <td class="tdInput">
                                            @Html.TextBoxFor(c => c.CategoryDescription, new { @class = "apps_inputbox", placeholder = "Enter New Categories Description" })
                                            @Html.ValidationMessageFor(c => c.CategoryDescription, "*", new {  })
                                        </td>
                                    </tr>
                                    <tr>
                                        <td>
                                            <label for="SortOrder">
                                                Order:</label>
                                        </td>
                                        <td class="tdInput">
                                            @Html.TextBoxFor(c => c.SortOrder, new { @class = "apps_inputbox", placeholder = "Sort Order" })
                                            @Html.ValidationMessageFor(c => c.SortOrder, "*", new { title = "Sort Order must be numeric value" })
                                        </td>
                                    </tr>
                                    <tr>
                                        <td>
                                            @Html.LabelFor(c => c.IsSingularSelection, "Singular:")
                                        </td>
                                        <td class="tdInput">
                                            @Html.CheckBoxFor(c => c.IsSingularSelection)
                                        </td>
                                    </tr>
                                    <tr>
                                        <td>
                                            @Html.LabelFor(c => c.IsRoot, "Root:")
                                        </td>
                                        <td class="tdInput">
                                            @Html.CheckBoxFor(c => c.IsRoot, new { onclick = "SetNotMergeable();" })
                                        </td>
                                    </tr>
                                    <tr id="trNotMergeable">
                                        <td>
                                            @Html.LabelFor(c => c.NotMergeable, "Not mergeable:")
                                        </td>
                                        <td class="tdInput">
                                            @Html.CheckBoxFor(c => c.NotMergeable)
                                        </td>
                                    </tr>
                                </table>
                                @Html.Hidden("ParentId")
                                <div class="zatify_panel_btn">
                                    <input name="" type="submit" class="btn apps_btn apps_gray_btn" value="Save" />
                                    <input id="btnCancel" name="" type="button" class="btn apps_btn apps_gray_btn" value="Cancel" />
                                </div>
                            </div>
                        </fieldset>
                    }
                </div>
            </td>
        </tr>
    </table>
</div>
